The present invention relates to a contact IC card for reading/writing data input from a predetermined terminal, and a non-contact IC card for reading/writing data via a radio interface. More specifically, the invention relates to an IC card which can assure on-processing data in the case where power supply and radio-wave supply are interrupted during communication, an IC chip and a data assuring method.
In recent years, IC cards which contain CPU and has a memory capacity larger than that of magnetic cards are introduced to various places. The IC cards are researched as succession of magnetic cards, and the IC cards are beginning to be adopted as, for example, credit cards and personal cards for storing welfare/health data. There exists a future plan that an IC card, which can be utilized as a multi-function card system which provides various card services using one card, and a card system which cooperates with another card service industry so as to provide more services, is allowed to spread.
There will be explained below an operation of a prior IC card. For example, a contact IC card receives a power supply from an upper apparatus by a power-supply terminal so that an IC chip in the IC card is actuated. More specifically, the contact IC card has terminals for a chip voltage (VCC), a reset signal (RST), a clock signal (CLK), a zero voltage (GND), an auxiliary voltage (VPP) and data transmission/receiving (I/O). The contact IC card is connected to a reader/writer, and receives VCC supply from the upper apparatus so as to execute various processes (reading, writing and the like) which synchronize with CLK.
Meanwhile, a non-contact IC card receives a radio wave from an upper apparatus, and converts the radio wave received in the IC card into a power supply so as to actuate an IC chip. More specifically, for example the non-contact IC card executes various processes (reading, writing and the like) by means of the upper apparatus connected to a reader/writer and a radio wave under the conditions that a center frequency is 13.56 MHz, a degree of modulation is 100%, a sub-carrier is none, a modulation technique is ASK, a coding system is Modified Miller and a communication speed is 106 kbps.
There will be explained below a flow of a data writing process in the prior IC card. FIG. 5 is a flow chart showing the flow of the data writing process. The upper apparatus transmits an updating command (including updated data) to the IC card (step S101), and waits for a response from the IC card.
Next, the IC card receives the updating command from the upper apparatus (step S102), and retrieves a data updating area based on control information stored inside (pointer information showing which area data are written by the previous process) (step S103). At this time, the IC card writes the updated data into a next area (address) of the area for the previous data stored in a memory area (step S104). After the data writing is completed, the IC card updates the control information (step S105), and transmits a response showing that the writing process is normally completed to the upper apparatus (step S106).
Finally, the upper apparatus receives the response from the IC card which is the communicating mate transmitting the updating command previously and ends a series of the data writing process (step S107).
In such a manner, the prior IC card rewrites data according to the control by means of the upper apparatus so that the data in the memory such as information about a credit card, personal information used for storing welfare/health data and fee information are always maintained in the latest state.
In addition, FIG. 6 is a diagram showing a power-supply monitor method by means of the prior IC card. In the prior IC card, a threshold value of the power supply which represents an operating area and an operation-forbidden area is provided. For example, when the power supply (VCC) is within a range of the operating area shown in the drawing, the writing process can be executed. Meanwhile, when VCC is within a range of the operation-forbidden area (high voltage area, low-voltage area), the operation is forcibly stopped. Thereafter, when VCC is returned to the operating area, the IC card is again activated.
As mentioned above, in the prior IC card, the power-supply area which assures the certain operation is previously provided to prevent a misoperation such that incorrect data are written into a memory.
However, a power supply is occasionally broken during writing in the IC card. More specifically, in the contact IC card, the following cases are considered as the causes: the case that a power supply from the upper apparatus is interrupted due to any trouble; the case that contact of the power-supply terminal is insufficient; and the case that the IC card comes off (including the case where the IC card is removed intentionally). On the other hand, in the non-contact IC card, the following cases are considered as the causes: the case that a radio wave from the upper apparatus is interrupted due to any trouble; and the case that a user of the IC card is separated from an area where a radio wave can be received.
In these cases, the prior IC cards have a problem such that the writing process is interrupted/ended even in the middle of writing.
More specifically, for example in the case where a power supply is interrupted (due to the above causes) at a stage that fourth-bit writing is completed in a 1-byte writing process (see FIG. 7), the remaining 4 bits data are not updated, and incorrect data which are not different from data to be originally written by CPU are possibly written into the memory. An example of this problem is that in the case where data to be written is fare data, fare data which do not match the fare to be originally updated are written. Moreover, since this state is not posted to CPU, xe2x80x9cmisoperation possibly occurs at the time of restartingxe2x80x9d. This occurs in the case where on-writing data are program.
In addition, in the prior IC cards, as explained in the prior art, since a threshold value of a power-supply area for assuring certain operation is previously provided, when a power supply is less than the threshold value, the operation is forcibly stopped.
Further, in the case where the operation is forcibly stopped as mentioned above and immediately after that the power supply is returned to the operating area, the prior IC cards require a reactivating process, and accordingly the processing speed is reduced.
It is an object of the invention to provide an IC card which can assure an operation of a writing cycle in the middle of processing even in the case where a power supply (contact IC card) or a radio wave (non-contact IC card) is not supplied due to any reasons, and a data assuring method.
Further, it is another object of the present invention to provide an IC card which sets an unstable area of a power supply is set as xe2x80x9cwaiting areaxe2x80x9d of CPU so as to realize high-speed processing, and a power-supply monitor method.
In order to solve the above problems and achieve the objects, an IC card from a first aspect of the invention for receiving a power supply or a radio wave from an upper apparatus so as to operate an internal IC chip, is characterized by including: a memory element capable of being used as a program memory and a work memory, the memory element for storing electric charges in a capacitor, wherein when a power supply is broken during a writing process so as to not to be supplied inside, the electric charges stored in the capacitor in the memory element are used so that a voltage for time required for completing a unit writing cycle is secured, and the current writing process is continued without interruption, and at a stage that the unit writing cycle is completed, the process is ended.
According to the invention, in the case where the supply of a radio wave from the upper apparatus is interrupted due to any trouble, in the case where a user of the IC card is separated from the area where a radio wave is received and the supply of the radio wave is interrupted, in the case where the supply of a power supply from the upper apparatus is interrupted due to any trouble, or in the case where the contact of the power-supply terminal is incomplete or the IC card comes off, the ferroelectric capacitor in the FeRAM is used so that a voltage for the time required for the remaining writing cycle can be secured. As a result, the writing data can be assured.
An IC card from a second aspect of the invention is characterized in that the memory element is a non-volatile memory having a structure that the voltage for the time required for completing the writing process can be secured.
According to the invention, in the case where the supply of a radio wave from the upper apparatus is interrupted due to any trouble, in the case where a user of the IC card is separated from the area where a radio wave is received and the supply of the radio wave is interrupted, in the case where the supply of a power supply from the upper apparatus is interrupted due to any trouble, or in the case where the contact of the power-supply terminal is incomplete or the IC card comes off, a non-volatile memory other than FeRAM is used so that a voltage for the time required for the remaining writing cycle can be secured.
An IC card from a third aspect of the invention, is characterized by further including: a power-supply monitor circuit for monitoring a voltage level of a power supply, wherein a judgment is made as to whether the current voltage level of the power supply is in an operating area showing an operable voltage range, in an operation-forbidden area showing an operation-forbidden voltage range, or in an operation waiting area showing an operation waiting voltage range, when the voltage level is changed from the operating area into the operation waiting area, the on-executing process is brought into the waiting state without ending the process, when the voltage level is changed from the operation waiting area into the operation-forbidden area, the operation is ended, and when the voltage level is changed from the operation waiting area into the operating area, the process in a waiting state is restarted.
According to the invention, when the area where the CPU is brought into the waiting state (operation waiting area) is provided between the operating area and the operation-forbidden area of low voltage, incorrect data are possibly written into the memory, but the operation of the IC card is not forcibly stopped and the CPU is first set into the waiting state in the voltage area which does not become a problem at all when the CPU waits. As a result, when the power-supply voltage is returned to the operating area, the reactivating process which is required for the prior arts is not necessary. Accordingly, a high-speed process can be realized.
An IC chip from a fourth aspect of the invention for receiving a power supply or a radio wave from an upper apparatus so as to be operated, is characterized by including: a memory element capable of being used as a program memory and a work memory, the memory element for storing electric charges in a capacitor, wherein when a power supply is broken during a writing process so as to not to be supplied inside, the electric charges stored in the capacitor in the memory element are used so that a voltage for time required for completing a unit writing cycle is secured, and the current writing process is continued without interruption, and at a stage that the unit writing cycle is completed, the process is ended.
According to the invention, in the case where the supply of a radio wave from the upper apparatus is interrupted due to any trouble, in the case where a user of the IC card is separated from the area where a radio wave is received and the supply of the radio wave is interrupted, in the case where the supply of a power supply from the upper apparatus is interrupted due to any trouble, or in the case where the contact of the power-supply terminal is incomplete or the IC card comes off, the ferroelectric capacitor in the FeRAM is used so that a voltage for the time required for the remaining writing cycle can be secured. As a result, the writing data can be assured.
An IC chip from a fifth aspect of the invention is characterized in that the memory element is a non-volatile memory having a structure that the voltage for the time required for completing the writing process can be secured.
According to the invention, in the case where the supply of a radio wave from the upper apparatus is interrupted due to any trouble, in the case where a user of the IC card is separated from the area where a radio wave is received and the supply of the radio wave is interrupted, in the case where the supply of a power supply from the upper apparatus is interrupted due to any trouble, or in the case where the contact of the power-supply terminal is incomplete or the IC card comes off, a non-volatile memory other than FeRAM is used so that a voltage for the time required for the remaining writing cycle can be secured.
An IC chip from a sixth aspect of the invention is characterized by further including: a power-supply monitor circuit for monitoring a voltage level of a power supply, wherein a judgment is made as to whether the current voltage level of the power supply is in an operating area showing an operable voltage range, in an operation-forbidden area showing an operation-forbidden voltage range, or in an operation waiting area showing an operation waiting voltage range, when the voltage level is changed from the operating area into the operation waiting area, the on-executing process is brought into the waiting state without ending the process, when the voltage level is changed from the operation waiting area into the operation-forbidden area, the operation is ended, and when the voltage level is changed from the operation waiting area into the operating area, the process in a waiting state is restarted.
According to the invention, when the area where the CPU is brought into the waiting state (operation waiting area) is provided between the operating area and the operation-forbidden area of low voltage, incorrect data are possibly written into the memory, but the operation of the IC chip is not forcibly stopped and the CPU is first set into the waiting state in the voltage area which does not become a problem at all when the CPU waits. As a result, when the power-supply voltage is returned to the operating area, the reactivating process which is required for the prior arts is not necessary. Accordingly, a high-speed process can be realized.
A data assuring method from a seventh aspect of the invention is characterized in that when a power supply is broken during a writing process so as not to be supplied into an IC card, electric charges stored in a capacitor in a memory element usable as a program memory and a work memory are used so that a voltage for time required for completing a unit writing cycle is secured, and the current writing process is continued without interruption, and at a stage that the unit writing cycle is completed, the process is ended.
According to the invention, in the case where the supply of a radio wave from the upper apparatus is interrupted due to any trouble, in the case where a user of the IC card is separated from the area where a radio wave is received and the supply of the radio wave is interrupted, in the case where the supply of a power supply from the upper apparatus is interrupted due to any trouble, or in the case where the contact of the power-supply terminal is incomplete or the IC card comes off, the ferroelectric, capacitor in the FeRAM is used so that a voltage for the time required for the remaining writing cycle can be secured. As a result, the writing data can be assured.
A power-supply monitor method from an eighth aspect of the invention is characterized by including the steps of: monitoring a voltage level of a power supply so as to make a judgment as to whether or not the voltage level is in an operating area showing an operable voltage range, in an operation-forbidden area showing an operation-forbidden voltage range or in an operation waiting area showing an operation waiting voltage range; when the voltage level is changed from the operating area into the operation waiting area, bringing the on-executing process into the waiting state without ending the process; when the voltage level is changed from the operation waiting area into the operation-forbidden area, ending the process; and when the voltage level is changed from the operation waiting area into the operating area, restarting the process in a waiting state.
According to the invention, when the area where the CPU is brought into the waiting state (operation waiting area) is provided between the operating area and the operation-forbidden area of low voltage, incorrect data are possibly written into the memory, but the operation of the IC card is not forcibly stopped and the CPU is first set into the waiting state in the voltage area which does not become a problem at all when the CPU waits. As a result, when the power-supply voltage is returned to the operating area, the reactivating process which is required for the prior arts is not necessary. Accordingly, a high-speed process can be realized.
Other objects and features of this invention will become understood from the following description with reference to the accompanying drawings.